<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8"/>
    <title> 3-4 改变 HTML 样式</title>
    <link rel="stylesheet" type="text/css" href="../../css/style.css"/>
    <script type="text/javascript">

    </script>
</head>

<body>
<div align="center">
    <p><a href="../index.php#js" class="fontSize" title="点击进入该目录">目录</a></p>
</div>

<h2 id="con">I love JavaScript</H2>
<p> JavaScript使网页显示动态效果并实现与用户交互功能。</p>

<script type="text/javascript">
    var mychar=document.getElementById("con");
    mychar.style.color="red";
    mychar.style.background="#ccc";
    mychar.style.width="300px";
</script>

</body>
</html>
